﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

using Joyintech.Common;
using Joyintech.BLL.inpiao365;
using Joyintech.Model.inpiao365;

namespace Joyintech.Admin.inpiao365.general.system.users
{
    public partial class delete : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!this.IsPostBack)
            {
                if (DNTRequest.GetQueryString("user_id") != "")
                {
                    int userid = Convert.ToInt32(DNTRequest.GetQueryString("user_id"));

                    systemUser_BLL _systemUser = new systemUser_BLL();

                    systemUser model = new systemUser();

                    model = _systemUser.GetModel(userid);

                    model.UserState = 2;

                    int dataResult = 0;

                    dataResult = _systemUser.Update(model);

                    if (dataResult == 1)
                    {
                        MessageBox.ShowMsgScript(this, "删除成功", "parent.location.href=parent.location.href;");
                    }
                }
            }
        }
    }
}